package com.sunyur.tailor.channel.web.outer.inventory.dto;

import lombok.Data;

import javax.validation.constraints.Digits;
import javax.validation.constraints.NotNull;
import java.math.BigDecimal;

/**
 * @ClassName RecordParam
 * @Description 库存流水
 * @Author xuhui
 * @Date 2021/6/21 16:21
 * @Version 1.0
 */
@Data
public class RecordParam {
    /**
     * 库存数量
     */
    @Digits(integer = 10, fraction = 2, message = "opNum格式不正确")
    @NotNull(message = "库存数量不能为空")
    private BigDecimal opNum;
    /**
     * 0--加库存，1--减库存
     */
    private Integer opType;

    public RecordParam() {
    }

    public RecordParam(BigDecimal opNum) {
        this.opNum = opNum;
    }
}
